#include <iostream>
#include <vector>
using namespace std;
class Solution {
public:
    vector<vector<int>> subsets(vector<int>& nums) {
        vector<vector<int>> subsets;
        int size = 1 << nums.size();
        for (int i = 0; i < size; ++i)
        {
            vector<int> temp;
            int num = i;
            int idx = 0;
            while(num)
            {
                if(num & 1)
                    temp.push_back(nums[idx]);
                num >>= 1;
                ++idx;
            }
            subsets.push_back(temp);
        }
        return subsets;
    }
};

int main()
{
    return 0;
}